package com.neuedu.springmvc.controller;

import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;
import org.springframework.web.bind.annotation.RestController;

import java.util.HashMap;
import java.util.Map;

/**
 * @author 金山
 * 项目：springmvc-learn
 * site: https://blog.fulfill.com.cn
 * 描述
 * @data 2025/3/1914:46
 */
@RestController
@RequestMapping("/test")
public class TestController {

    @ResponseBody
    @RequestMapping
    String index(){

        return "测试中文乱码111";
    }

    @ResponseBody
    @RequestMapping("/json")
    Map json(){
        Map info = new HashMap();
        info.put("name","张三");
        info.put("age",189);
        return info;
    }
}
